package com.atguigu.common.exception;

import lombok.Getter;

@Getter
public enum BizCodeEnum {
    /**
     * 方法描述
     */
    VALID_EXCEPTION(10000,"参数格式校验失败"),
    UNKNOW_EXCEPTION(10001, "系统未知异常"),
    TO_MANY_REQUEST_GATEWAY(10002,"【网关】请求流量过大，请稍后再试"),
    TO_MANY_REQUEST_SERVICE(10003,"【微服务】请求流量过大，请稍后再试"),
    TO_MANY_REQUEST_FEIGN(10003,"【FEIGN】请求流量过大，请稍后再试"),
    PRODUCT_INDEX_EXCEPTION(11000,"批量保存sku至索引库异常"),
    USER_EXIST_EXCEPTION(15001,"用户已存在"),
    PHONE_EXIST_EXCEPTION(15002,"手机号码已存在"),
    PHONE_NULL_EXCEPTION(15003,"未输入手机号码"),
    LOGINACCT_PASSWORD_INVAILD_EXCEPTION(15004,"账号或密码错误"),
    SMS_CODE_EXCEPTION(15005,"发送验证码太频繁,请稍后再试"),
    NO_STOCK_EXCEPTION(21000,"商品库存不足"),;

    int code;
    String message;

    BizCodeEnum(int code,String message){
        this.code = code;
        this.message = message;
    }
}
